<template>
  <input type="file" @change="onChange" />
</template>

<script lang="ts" setup>
import { getFileChunkListAndHash } from '@/utils'

function onChange(event: Event) {
  const file = (event.target as HTMLInputElement).files?.[0] as File

  getFileChunkListAndHash(file).then((value) => {
    console.log('value.chunkList', value.chunkList)
    console.log('value.hash', value.hash)
  })
}
</script>
